package com.xyd.common.result;

import lombok.Data;

/**
 * 枚举：将所有得可能一一列举
 */

public enum ResultStatusEnum {
    SUCCESS(20000,"成功"),
    FAIL(4001,"失败"),
    SERVER_ERROR(4005,"服务器异常"),
    DATA_ERROR(4006,"数据异常"),
    LOGIN_AUTH(4002,"未登录"),
    PERMISSION(4003,"没有权限")
    ;

    private int status;
    private String message;
    // 全参构造器
    private ResultStatusEnum(int status, String message) {
        this.status = status;
        this.message = message;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
